package com.zy.ivideo.controller;

import com.zy.ivideo.entity.ResponseEntity;
import com.zy.ivideo.service.SyncVideoService;
import com.zy.ivideo.token.UserToken;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import springfox.documentation.annotations.ApiIgnore;

@RestController
@RequestMapping("/sync")
@ApiIgnore
@Api(value = "快手视频数据同步模块API接口", description = "该模块提供快手视频数据同步服务", tags = "快手视频数据同步模块")
public class KSVideoController {
    @Autowired
    SyncVideoService service;

    @UserToken
    @ApiOperation(value = "同步快手视频数据", notes = "同步快手视频数据", httpMethod = "POST")
    @PostMapping("/sync")
    public ResponseEntity<Boolean> sync(){
        return service.sync();
    }
}
